Integrand size = 31, antiderivative size = 164 \[ \int (A+B x) (d+e x) \sqrt {a^2+2 a b x+b^2 x^2} \, dx=\frac {a A d x \sqrt {a^2+2 a b x+b^2 x^2}}{a+b x}+\frac {(A b d+a B d+a A e) x^2 \sqrt {a^2+2 a b x+b^2 x^2}}{2 (a+b x)}+\frac {(b B d+A b e+a B e) x^3 \sqrt {a^2+2 a b x+b^2 x^2}}{3 (a+b x)}+\frac {b B e x^4 \sqrt {a^2+2 a b x+b^2 x^2}}{4 (a+b x)} \]
a*A*d*x*((b*x+a)^2)^(1/2)/(b*x+a)+1/2*(A*a*e+A*b*d+B*a*d)*x^2*((b*x+a)^2)^ (1/2)/(b*x+a)+1/3*(A*b*e+B*a*e+B*b*d)*x^3*((b*x+a)^2)^(1/2)/(b*x+a)+1/4*b* B*e*x^4*((b*x+a)^2)^(1/2)/(b*x+a)
Time = 1.02 (sec) , antiderivative size = 74, normalized size of antiderivative = 0.45 \[ \int (A+B x) (d+e x) \sqrt {a^2+2 a b x+b^2 x^2} \, dx=\frac {x \sqrt {(a+b x)^2} (2 a (3 A (2 d+e x)+B x (3 d+2 e x))+b x (B x (4 d+3 e x)+A (6 d+4 e x)))}{12 (a+b x)} \]
(x*Sqrt[(a + b*x)^2]*(2*a*(3*A*(2*d + e*x) + B*x*(3*d + 2*e*x)) + b*x*(B*x *(4*d + 3*e*x) + A*(6*d + 4*e*x))))/(12*(a + b*x))
Time = 0.26 (sec) , antiderivative size = 84, normalized size of antiderivative = 0.51, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.129, Rules used = {1187, 27, 86, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \sqrt {a^2+2 a b x+b^2 x^2} (A+B x) (d+e x) \, dx\) |
\(\Big \downarrow \) 1187 |
\(\displaystyle \frac {\sqrt {a^2+2 a b x+b^2 x^2} \int b (a+b x) (A+B x) (d+e x)dx}{b (a+b x)}\) |
\(\Big \downarrow \) 27 |
\(\displaystyle \frac {\sqrt {a^2+2 a b x+b^2 x^2} \int (a+b x) (A+B x) (d+e x)dx}{a+b x}\) |
\(\Big \downarrow \) 86 |
\(\displaystyle \frac {\sqrt {a^2+2 a b x+b^2 x^2} \int \left (b B e x^3+(b B d+A b e+a B e) x^2+(A b d+a B d+a A e) x+a A d\right )dx}{a+b x}\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {\sqrt {a^2+2 a b x+b^2 x^2} \left (\frac {1}{3} x^3 (a B e+A b e+b B d)+\frac {1}{2} x^2 (a A e+a B d+A b d)+a A d x+\frac {1}{4} b B e x^4\right )}{a+b x}\) |
(Sqrt[a^2 + 2*a*b*x + b^2*x^2]*(a*A*d*x + ((A*b*d + a*B*d + a*A*e)*x^2)/2 + ((b*B*d + A*b*e + a*B*e)*x^3)/3 + (b*B*e*x^4)/4))/(a + b*x)
3.18.11.3.1 Defintions of rubi rules used
Int[(a_)*(Fx_), x_Symbol] :> Simp[a Int[Fx, x], x] /; FreeQ[a, x] && !Ma tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
Int[((a_.) + (b_.)*(x_))*((c_) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_ .), x_] :> Int[ExpandIntegrand[(a + b*x)*(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, n}, x] && ((ILtQ[n, 0] && ILtQ[p, 0]) || EqQ[p, 1 ] || (IGtQ[p, 0] && ( !IntegerQ[n] || LeQ[9*p + 5*(n + 2), 0] || GeQ[n + p + 1, 0] || (GeQ[n + p + 2, 0] && RationalQ[a, b, c, d, e, f]))))
Int[((d_.) + (e_.)*(x_))^(m_.)*((f_.) + (g_.)*(x_))^(n_.)*((a_) + (b_.)*(x_ ) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Simp[(a + b*x + c*x^2)^FracPart[p]/(c^ IntPart[p]*(b/2 + c*x)^(2*FracPart[p])) Int[(d + e*x)^m*(f + g*x)^n*(b/2 + c*x)^(2*p), x], x] /; FreeQ[{a, b, c, d, e, f, g, m, n, p}, x] && EqQ[b^2 - 4*a*c, 0] && !IntegerQ[p]
Time = 0.08 (sec) , antiderivative size = 76, normalized size of antiderivative = 0.46
method | result | size |
gosper | \(\frac {x \left (3 B b e \,x^{3}+4 x^{2} A b e +4 x^{2} B a e +4 x^{2} B b d +6 x a A e +6 x A b d +6 x B a d +12 d A a \right ) \sqrt {\left (b x +a \right )^{2}}}{12 b x +12 a}\) | \(76\) |
default | \(-\frac {\operatorname {csgn}\left (b x +a \right ) \left (b x +a \right )^{2} \left (-3 B e \,x^{2} b^{2}-4 A \,b^{2} e x +2 B a b e x -4 B \,b^{2} d x +2 A a b e -6 A d \,b^{2}-B e \,a^{2}+2 B a b d \right )}{12 b^{3}}\) | \(79\) |
risch | \(\frac {b B e \,x^{4} \sqrt {\left (b x +a \right )^{2}}}{4 b x +4 a}+\frac {\sqrt {\left (b x +a \right )^{2}}\, \left (\left (a e +b d \right ) B +A b e \right ) x^{3}}{3 b x +3 a}+\frac {\sqrt {\left (b x +a \right )^{2}}\, \left (B a d +\left (a e +b d \right ) A \right ) x^{2}}{2 b x +2 a}+\frac {a A d x \sqrt {\left (b x +a \right )^{2}}}{b x +a}\) | \(117\) |
1/12*x*(3*B*b*e*x^3+4*A*b*e*x^2+4*B*a*e*x^2+4*B*b*d*x^2+6*A*a*e*x+6*A*b*d* x+6*B*a*d*x+12*A*a*d)*((b*x+a)^2)^(1/2)/(b*x+a)
Time = 0.31 (sec) , antiderivative size = 52, normalized size of antiderivative = 0.32 \[ \int (A+B x) (d+e x) \sqrt {a^2+2 a b x+b^2 x^2} \, dx=\frac {1}{4} \, B b e x^{4} + A a d x + \frac {1}{3} \, {\left (B b d + {\left (B a + A b\right )} e\right )} x^{3} + \frac {1}{2} \, {\left (A a e + {\left (B a + A b\right )} d\right )} x^{2} \]
Time = 1.75 (sec) , antiderivative size = 393, normalized size of antiderivative = 2.40 \[ \int (A+B x) (d+e x) \sqrt {a^2+2 a b x+b^2 x^2} \, dx=A d \left (\begin {cases} \left (\frac {a}{2 b} + \frac {x}{2}\right ) \sqrt {a^{2} + 2 a b x + b^{2} x^{2}} & \text {for}\: b^{2} \neq 0 \\\frac {\left (a^{2} + 2 a b x\right )^{\frac {3}{2}}}{3 a b} & \text {for}\: a b \neq 0 \\x \sqrt {a^{2}} & \text {otherwise} \end {cases}\right ) + A e \left (\begin {cases} \sqrt {a^{2} + 2 a b x + b^{2} x^{2}} \left (- \frac {a^{2}}{6 b^{2}} + \frac {a x}{6 b} + \frac {x^{2}}{3}\right ) & \text {for}\: b^{2} \neq 0 \\\frac {- \frac {a^{2} \left (a^{2} + 2 a b x\right )^{\frac {3}{2}}}{3} + \frac {\left (a^{2} + 2 a b x\right )^{\frac {5}{2}}}{5}}{2 a^{2} b^{2}} & \text {for}\: a b \neq 0 \\\frac {x^{2} \sqrt {a^{2}}}{2} & \text {otherwise} \end {cases}\right ) + B d \left (\begin {cases} \sqrt {a^{2} + 2 a b x + b^{2} x^{2}} \left (- \frac {a^{2}}{6 b^{2}} + \frac {a x}{6 b} + \frac {x^{2}}{3}\right ) & \text {for}\: b^{2} \neq 0 \\\frac {- \frac {a^{2} \left (a^{2} + 2 a b x\right )^{\frac {3}{2}}}{3} + \frac {\left (a^{2} + 2 a b x\right )^{\frac {5}{2}}}{5}}{2 a^{2} b^{2}} & \text {for}\: a b \neq 0 \\\frac {x^{2} \sqrt {a^{2}}}{2} & \text {otherwise} \end {cases}\right ) + B e \left (\begin {cases} \sqrt {a^{2} + 2 a b x + b^{2} x^{2}} \left (\frac {a^{3}}{12 b^{3}} - \frac {a^{2} x}{12 b^{2}} + \frac {a x^{2}}{12 b} + \frac {x^{3}}{4}\right ) & \text {for}\: b^{2} \neq 0 \\\frac {\frac {a^{4} \left (a^{2} + 2 a b x\right )^{\frac {3}{2}}}{3} - \frac {2 a^{2} \left (a^{2} + 2 a b x\right )^{\frac {5}{2}}}{5} + \frac {\left (a^{2} + 2 a b x\right )^{\frac {7}{2}}}{7}}{4 a^{3} b^{3}} & \text {for}\: a b \neq 0 \\\frac {x^{3} \sqrt {a^{2}}}{3} & \text {otherwise} \end {cases}\right ) \]
A*d*Piecewise(((a/(2*b) + x/2)*sqrt(a**2 + 2*a*b*x + b**2*x**2), Ne(b**2, 0)), ((a**2 + 2*a*b*x)**(3/2)/(3*a*b), Ne(a*b, 0)), (x*sqrt(a**2), True)) + A*e*Piecewise((sqrt(a**2 + 2*a*b*x + b**2*x**2)*(-a**2/(6*b**2) + a*x/(6 *b) + x**2/3), Ne(b**2, 0)), ((-a**2*(a**2 + 2*a*b*x)**(3/2)/3 + (a**2 + 2 *a*b*x)**(5/2)/5)/(2*a**2*b**2), Ne(a*b, 0)), (x**2*sqrt(a**2)/2, True)) + B*d*Piecewise((sqrt(a**2 + 2*a*b*x + b**2*x**2)*(-a**2/(6*b**2) + a*x/(6* b) + x**2/3), Ne(b**2, 0)), ((-a**2*(a**2 + 2*a*b*x)**(3/2)/3 + (a**2 + 2* a*b*x)**(5/2)/5)/(2*a**2*b**2), Ne(a*b, 0)), (x**2*sqrt(a**2)/2, True)) + B*e*Piecewise((sqrt(a**2 + 2*a*b*x + b**2*x**2)*(a**3/(12*b**3) - a**2*x/( 12*b**2) + a*x**2/(12*b) + x**3/4), Ne(b**2, 0)), ((a**4*(a**2 + 2*a*b*x)* *(3/2)/3 - 2*a**2*(a**2 + 2*a*b*x)**(5/2)/5 + (a**2 + 2*a*b*x)**(7/2)/7)/( 4*a**3*b**3), Ne(a*b, 0)), (x**3*sqrt(a**2)/3, True))
Leaf count of result is larger than twice the leaf count of optimal. 254 vs. \(2 (114) = 228\).
Time = 0.19 (sec) , antiderivative size = 254, normalized size of antiderivative = 1.55 \[ \int (A+B x) (d+e x) \sqrt {a^2+2 a b x+b^2 x^2} \, dx=\frac {1}{2} \, \sqrt {b^{2} x^{2} + 2 \, a b x + a^{2}} A d x + \frac {\sqrt {b^{2} x^{2} + 2 \, a b x + a^{2}} B a^{2} e x}{2 \, b^{2}} + \frac {\sqrt {b^{2} x^{2} + 2 \, a b x + a^{2}} A a d}{2 \, b} + \frac {\sqrt {b^{2} x^{2} + 2 \, a b x + a^{2}} B a^{3} e}{2 \, b^{3}} - \frac {\sqrt {b^{2} x^{2} + 2 \, a b x + a^{2}} {\left (B d + A e\right )} a x}{2 \, b} + \frac {{\left (b^{2} x^{2} + 2 \, a b x + a^{2}\right )}^{\frac {3}{2}} B e x}{4 \, b^{2}} - \frac {\sqrt {b^{2} x^{2} + 2 \, a b x + a^{2}} {\left (B d + A e\right )} a^{2}}{2 \, b^{2}} - \frac {5 \, {\left (b^{2} x^{2} + 2 \, a b x + a^{2}\right )}^{\frac {3}{2}} B a e}{12 \, b^{3}} + \frac {{\left (b^{2} x^{2} + 2 \, a b x + a^{2}\right )}^{\frac {3}{2}} {\left (B d + A e\right )}}{3 \, b^{2}} \]
1/2*sqrt(b^2*x^2 + 2*a*b*x + a^2)*A*d*x + 1/2*sqrt(b^2*x^2 + 2*a*b*x + a^2 )*B*a^2*e*x/b^2 + 1/2*sqrt(b^2*x^2 + 2*a*b*x + a^2)*A*a*d/b + 1/2*sqrt(b^2 *x^2 + 2*a*b*x + a^2)*B*a^3*e/b^3 - 1/2*sqrt(b^2*x^2 + 2*a*b*x + a^2)*(B*d + A*e)*a*x/b + 1/4*(b^2*x^2 + 2*a*b*x + a^2)^(3/2)*B*e*x/b^2 - 1/2*sqrt(b ^2*x^2 + 2*a*b*x + a^2)*(B*d + A*e)*a^2/b^2 - 5/12*(b^2*x^2 + 2*a*b*x + a^ 2)^(3/2)*B*a*e/b^3 + 1/3*(b^2*x^2 + 2*a*b*x + a^2)^(3/2)*(B*d + A*e)/b^2
Time = 0.29 (sec) , antiderivative size = 155, normalized size of antiderivative = 0.95 \[ \int (A+B x) (d+e x) \sqrt {a^2+2 a b x+b^2 x^2} \, dx=\frac {1}{4} \, B b e x^{4} \mathrm {sgn}\left (b x + a\right ) + \frac {1}{3} \, B b d x^{3} \mathrm {sgn}\left (b x + a\right ) + \frac {1}{3} \, B a e x^{3} \mathrm {sgn}\left (b x + a\right ) + \frac {1}{3} \, A b e x^{3} \mathrm {sgn}\left (b x + a\right ) + \frac {1}{2} \, B a d x^{2} \mathrm {sgn}\left (b x + a\right ) + \frac {1}{2} \, A b d x^{2} \mathrm {sgn}\left (b x + a\right ) + \frac {1}{2} \, A a e x^{2} \mathrm {sgn}\left (b x + a\right ) + A a d x \mathrm {sgn}\left (b x + a\right ) - \frac {{\left (2 \, B a^{3} b d - 6 \, A a^{2} b^{2} d - B a^{4} e + 2 \, A a^{3} b e\right )} \mathrm {sgn}\left (b x + a\right )}{12 \, b^{3}} \]
1/4*B*b*e*x^4*sgn(b*x + a) + 1/3*B*b*d*x^3*sgn(b*x + a) + 1/3*B*a*e*x^3*sg n(b*x + a) + 1/3*A*b*e*x^3*sgn(b*x + a) + 1/2*B*a*d*x^2*sgn(b*x + a) + 1/2 *A*b*d*x^2*sgn(b*x + a) + 1/2*A*a*e*x^2*sgn(b*x + a) + A*a*d*x*sgn(b*x + a ) - 1/12*(2*B*a^3*b*d - 6*A*a^2*b^2*d - B*a^4*e + 2*A*a^3*b*e)*sgn(b*x + a )/b^3
Time = 11.18 (sec) , antiderivative size = 223, normalized size of antiderivative = 1.36 \[ \int (A+B x) (d+e x) \sqrt {a^2+2 a b x+b^2 x^2} \, dx=\frac {B\,d\,\left (8\,b^2\,\left (a^2+b^2\,x^2\right )-12\,a^2\,b^2+4\,a\,b^3\,x\right )\,\sqrt {a^2+2\,a\,b\,x+b^2\,x^2}}{24\,b^4}+\frac {B\,e\,x\,{\left (a^2+2\,a\,b\,x+b^2\,x^2\right )}^{3/2}}{4\,b^2}+\frac {A\,\left (a+b\,x\right )\,\left (3\,b\,d-a\,e+2\,b\,e\,x\right )\,\sqrt {a^2+2\,a\,b\,x+b^2\,x^2}}{6\,b^2}-\frac {B\,a^2\,e\,\left (\frac {x}{2}+\frac {a}{2\,b}\right )\,\sqrt {a^2+2\,a\,b\,x+b^2\,x^2}}{4\,b^2}-\frac {5\,B\,a\,e\,\left (8\,b^2\,\left (a^2+b^2\,x^2\right )-12\,a^2\,b^2+4\,a\,b^3\,x\right )\,\sqrt {a^2+2\,a\,b\,x+b^2\,x^2}}{96\,b^5} \]
(B*d*(8*b^2*(a^2 + b^2*x^2) - 12*a^2*b^2 + 4*a*b^3*x)*(a^2 + b^2*x^2 + 2*a *b*x)^(1/2))/(24*b^4) + (B*e*x*(a^2 + b^2*x^2 + 2*a*b*x)^(3/2))/(4*b^2) + (A*(a + b*x)*(3*b*d - a*e + 2*b*e*x)*(a^2 + b^2*x^2 + 2*a*b*x)^(1/2))/(6*b ^2) - (B*a^2*e*(x/2 + a/(2*b))*(a^2 + b^2*x^2 + 2*a*b*x)^(1/2))/(4*b^2) - (5*B*a*e*(8*b^2*(a^2 + b^2*x^2) - 12*a^2*b^2 + 4*a*b^3*x)*(a^2 + b^2*x^2 + 2*a*b*x)^(1/2))/(96*b^5)